package com.temple.web.controller;

import com.alibaba.fastjson.JSON;
import com.temple.model.dto.FeatureUserInfo;
import com.temple.service.IUserService;
import io.swagger.annotations.Api;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @description:
 * @author: yanchao
 * @time: 2021-12-28 17:37
 */
@Slf4j
@RestController
@RequestMapping("test")
public class TestController {


    @Autowired
    private IUserService iUserService;

    @GetMapping("/put")
    public void put(){

        FeatureUserInfo userInfo = new FeatureUserInfo();
        userInfo.setUserName("张三");
        userInfo.setAge(4);
        Boolean flag = iUserService.putFeature(9, "userInfo", JSON.toJSON(userInfo));
        log.info("=============结果:{}",flag);

    }
}
